package initialize

import (
	"fmt"
	uuid "github.com/satori/go.uuid"
	"os"
	"user_srv/global"
)

func init() {
	global.RootPath, _ = os.Getwd()
	//初始化配置
	InitConfig()
	global.ServerID = fmt.Sprintf("%s", uuid.NewV4())
	//获取空端口号
	InitGetFreePort()
	//初始化日志
	InitLogger()
	//初始化数据库
	InitMysql()
	//初始化consul
	InitRegisterConsul()
}
